function volarea(x)
%VOLAREA Price and volume chart.
%   VOLAREA(X) plots the asset data price and volume on a single axis.
%   X contains the asset data in columns date, price, and volume.
%
%   See also BOLLING, CANDLE, HIGHLOW, LINEBREAK, MOVAVG, POINTFIG, PRICEANDVOL, KAGI, RENKO.

%	Copyright 1995-2007 The MathWorks, Inc.
%	$Revision: 1.1.6.2 $   $Date: 2007/11/22 16:40:06 $

%Plot price and volume as areas
[ax,h1,h2] = plotyy(x(:,1),x(:,3),x(:,1),x(:,2),'area');

%Set display
set(h2,'edgecolor','black','facecolor','none','linewidth',2)
h1color = [.65 0 0];
set(h1,'edgecolor',h1color,'facecolor',h1color)
grid on

%Display date labels
datetick(ax(1))
set(ax,'Xlim',[min(x(:,1))+1 max(x(:,1))-1],'Tag','volareachart')
set(ax(2),'Xticklabel',[],'Yaxislocation','left')
set(ax(1),'Yaxislocation','right')
